3.20 \(\int \frac{(A+B x) (b x+c x^2)^2}{x^2} \, dx\)

Optimal. Leaf size=38 \[ \frac{B (b+c x)^4}{4 c^2}-\frac{(b+c x)^3 (b B-A c)}{3 c^2} \]

[Out]

-((b*B - A*c)*(b + c*x)^3)/(3*c^2) + (B*(b + c*x)^4)/(4*c^2)

________________________________________________________________________________________

Rubi [A]  time = 0.027039, antiderivative size = 38, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 20, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.05, Rules used = {765} \[ \frac{B (b+c x)^4}{4 c^2}-\frac{(b+c x)^3 (b B-A c)}{3 c^2} \]

Antiderivative was successfully verified.

[In]

Int[((A + B*x)*(b*x + c*x^2)^2)/x^2,x]

[Out]

-((b*B - A*c)*(b + c*x)^3)/(3*c^2) + (B*(b + c*x)^4)/(4*c^2)

Rule 765

Int[((e_.)*(x_))^(m_.)*((f_.) + (g_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[Expand
Integrand[(e*x)^m*(f + g*x)*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, e, f, g, m}, x] && IntegerQ[p] && (
GtQ[p, 0] || (EqQ[a, 0] && IntegerQ[m]))

Rubi steps

\begin{align*} \int \frac{(A+B x) \left (b x+c x^2\right )^2}{x^2} \, dx &=\int \left (\frac{(-b B+A c) (b+c x)^2}{c}+\frac{B (b+c x)^3}{c}\right ) \, dx\\ &=-\frac{(b B-A c) (b+c x)^3}{3 c^2}+\frac{B (b+c x)^4}{4 c^2}\\ \end{align*}

Mathematica [A]  time = 0.0099015, size = 47, normalized size = 1.24 \[ \frac{1}{12} x \left (12 A b^2+4 c x^2 (A c+2 b B)+6 b x (2 A c+b B)+3 B c^2 x^3\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[((A + B*x)*(b*x + c*x^2)^2)/x^2,x]

[Out]

(x*(12*A*b^2 + 6*b*(b*B + 2*A*c)*x + 4*c*(2*b*B + A*c)*x^2 + 3*B*c^2*x^3))/12

________________________________________________________________________________________

Maple [A]  time = 0.001, size = 49, normalized size = 1.3 \begin{align*}{\frac{B{c}^{2}{x}^{4}}{4}}+{\frac{ \left ( A{c}^{2}+2\,Bbc \right ){x}^{3}}{3}}+{\frac{ \left ( 2\,Abc+{b}^{2}B \right ){x}^{2}}{2}}+A{b}^{2}x \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((B*x+A)*(c*x^2+b*x)^2/x^2,x)

[Out]

1/4*B*c^2*x^4+1/3*(A*c^2+2*B*b*c)*x^3+1/2*(2*A*b*c+B*b^2)*x^2+A*b^2*x

________________________________________________________________________________________

Maxima [A]  time = 1.13911, size = 65, normalized size = 1.71 \begin{align*} \frac{1}{4} \, B c^{2} x^{4} + A b^{2} x + \frac{1}{3} \,{\left (2 \, B b c + A c^{2}\right )} x^{3} + \frac{1}{2} \,{\left (B b^{2} + 2 \, A b c\right )} x^{2} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)*(c*x^2+b*x)^2/x^2,x, algorithm="maxima")

[Out]

1/4*B*c^2*x^4 + A*b^2*x + 1/3*(2*B*b*c + A*c^2)*x^3 + 1/2*(B*b^2 + 2*A*b*c)*x^2

________________________________________________________________________________________

Fricas [A]  time = 1.80916, size = 109, normalized size = 2.87 \begin{align*} \frac{1}{4} \, B c^{2} x^{4} + A b^{2} x + \frac{1}{3} \,{\left (2 \, B b c + A c^{2}\right )} x^{3} + \frac{1}{2} \,{\left (B b^{2} + 2 \, A b c\right )} x^{2} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)*(c*x^2+b*x)^2/x^2,x, algorithm="fricas")

[Out]

1/4*B*c^2*x^4 + A*b^2*x + 1/3*(2*B*b*c + A*c^2)*x^3 + 1/2*(B*b^2 + 2*A*b*c)*x^2

________________________________________________________________________________________

Sympy [A]  time = 0.07274, size = 49, normalized size = 1.29 \begin{align*} A b^{2} x + \frac{B c^{2} x^{4}}{4} + x^{3} \left (\frac{A c^{2}}{3} + \frac{2 B b c}{3}\right ) + x^{2} \left (A b c + \frac{B b^{2}}{2}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)*(c*x**2+b*x)**2/x**2,x)

[Out]

A*b**2*x + B*c**2*x**4/4 + x**3*(A*c**2/3 + 2*B*b*c/3) + x**2*(A*b*c + B*b**2/2)

________________________________________________________________________________________

Giac [A]  time = 1.15935, size = 66, normalized size = 1.74 \begin{align*} \frac{1}{4} \, B c^{2} x^{4} + \frac{2}{3} \, B b c x^{3} + \frac{1}{3} \, A c^{2} x^{3} + \frac{1}{2} \, B b^{2} x^{2} + A b c x^{2} + A b^{2} x \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)*(c*x^2+b*x)^2/x^2,x, algorithm="giac")

[Out]

1/4*B*c^2*x^4 + 2/3*B*b*c*x^3 + 1/3*A*c^2*x^3 + 1/2*B*b^2*x^2 + A*b*c*x^2 + A*b^2*x